<?php
// 获取商户类表

header("Content-type:text/html;charset=UTF-8");

session_start();
if (empty($_SESSION['id'])) {
    echo '{"code":"400","msg":"未登录"}';

    die();
}
// 接收post 请求
$id = addslashes($_POST['id']);
// $id = 1;
$conn = mysqli_connect('127.0.0.1', 'root', 'root', 'lzp');
mysqli_query($conn, 'set names utf8');
$sql = "update p_tn18 set is_true='0' where id=$id";
//执行 sql
$result = mysqli_query($conn, $sql);


// $info = mysqli_fetch_assoc($result);

// var_dump($result) ;
if ($result==true) {
    echo 1;
}else{
    echo 2;
}